package produce_consume;

public class A {
    public static void main(String[] args) throws Exception {
        E.test1();
        E.test2();
        E.test3();
    }
}

class B extends Exception {

}

class C extends B {

}

class D extends RuntimeException {

}

class E {
    public static void test1() throws B {
        throw new B();
    }

    public static void test2() throws C {
        throw new C();
    }

    public static void test3(){
        throw new D();
    }
}
